/**********************************************
这是代码自动生成的，如果重新生成，所做的改动将会丢失
系统:Itop隐患排查
模块:系统平台
Itop.com 版权所有
生成者：Rabbit
生成时间:2011-12-5 14:19:30
***********************************************/

using System;
using System.Threading;
using System.ComponentModel;
namespace Itop.YHPC.Model
{
    /// <summary>
    ///[yhpcWf]业务实体类
    ///对应表名:yhpcWf
    /// </summary>
    [Serializable]
    public class yhpcWf
    {
        
        #region Private 成员
        private string _id=String.Empty; 
        private string _hjid=Newid(); 
        private int _orderid=0; 
        private string _dm=String.Empty; 
        private string _mc=String.Empty; 
        private string _url1=String.Empty; 
        private string _url2=String.Empty;   
        #endregion
  
  
        #region Public 成员
   
        /// <summary>
        /// 属性名称：id
        /// 属性描述：流程ID
        /// 字段信息：[id],nvarchar
        /// </summary>
        [DisplayNameAttribute("流程ID")]
        public string id
        {
            get { return _id; }
            set
            {			
                if(value==null)return;
                if( value.ToString().Length > 50)
                throw new Exception("[流程ID]长度不能大于50!");
                if (_id as object == null || !_id.Equals(value))
                {
                    _id = value;
                }
            }			 
        }
  
        /// <summary>
        /// 属性名称：hjID
        /// 属性描述：环节ID
        /// 字段信息：[hjID],nvarchar
        /// </summary>
        [Browsable(false)]
        [DisplayNameAttribute("环节ID")]
        public string hjID
        {
            get { return _hjid; }
            set
            {			
                if(value==null)return;
                if( value.ToString().Length > 50)
                throw new Exception("[环节ID]长度不能大于50!");
                if (_hjid as object == null || !_hjid.Equals(value))
                {
                    _hjid = value;
                }
            }			 
        }
  
        /// <summary>
        /// 属性名称：orderID
        /// 属性描述：顺序号
        /// 字段信息：[orderID],int
        /// </summary>
        [DisplayNameAttribute("顺序号")]
        public int orderID
        {
            get { return _orderid; }
            set
            {			
                if (_orderid as object == null || !_orderid.Equals(value))
                {
                    _orderid = value;
                }
            }			 
        }
  
        /// <summary>
        /// 属性名称：dm
        /// 属性描述：环节代码
        /// 字段信息：[dm],nvarchar
        /// </summary>
        [DisplayNameAttribute("环节代码")]
        public string dm
        {
            get { return _dm; }
            set
            {			
                if(value==null)return;
                if( value.ToString().Length > 50)
                throw new Exception("[环节代码]长度不能大于50!");
                if (_dm as object == null || !_dm.Equals(value))
                {
                    _dm = value;
                }
            }			 
        }
  
        /// <summary>
        /// 属性名称：mc
        /// 属性描述：环节名称
        /// 字段信息：[mc],nvarchar
        /// </summary>
        [DisplayNameAttribute("环节名称")]
        public string mc
        {
            get { return _mc; }
            set
            {			
                if(value==null)return;
                if( value.ToString().Length > 50)
                throw new Exception("[环节名称]长度不能大于50!");
                if (_mc as object == null || !_mc.Equals(value))
                {
                    _mc = value;
                }
            }			 
        }
  
        /// <summary>
        /// 属性名称：url1
        /// 属性描述：超连接1
        /// 字段信息：[url1],nvarchar
        /// </summary>
        [DisplayNameAttribute("超连接1")]
        public string url1
        {
            get { return _url1; }
            set
            {			
                if(value==null)return;
                if( value.ToString().Length > 250)
                throw new Exception("[超连接1]长度不能大于250!");
                if (_url1 as object == null || !_url1.Equals(value))
                {
                    _url1 = value;
                }
            }			 
        }
  
        /// <summary>
        /// 属性名称：url2
        /// 属性描述：超连接2
        /// 字段信息：[url2],nvarchar
        /// </summary>
        [DisplayNameAttribute("超连接2")]
        public string url2
        {
            get { return _url2; }
            set
            {			
                if(value==null)return;
                if( value.ToString().Length > 250)
                throw new Exception("[超连接2]长度不能大于250!");
                if (_url2 as object == null || !_url2.Equals(value))
                {
                    _url2 = value;
                }
            }			 
        }
  
        #endregion 
  
        #region 方法
        public static string Newid(){
            return DateTime.Now.ToString("yyyyMMddHHmmssffffff");
        }
        public string CreateID(){
            Thread.Sleep(new TimeSpan(100000));//0.1毫秒
            return DateTime.Now.ToString("yyyyMMddHHmmssffffff");
        }
        #endregion		
    }	
}
